<!doctype html>
<html lang="zn">
<head>
    <% include 'shared/head' %>
    <link rel="stylesheet" href="/dist/phone-commons.js.css">
    <link rel="stylesheet" href="/dist/phone-home.css"/>
</head>
<body>
<div class="am-g am-g-collapse" ng-controller="MainCtrl">
    <div class="main am-u-sm-12">
        <header id="phone-header" class="fix-header" ng-controller="LocationCtrl" ng-click="slide()">
            <img class="fix-header-logo" src="/logo.png">

            <div class="search">
                <div class="fix-header-location"><i class="am-icon-map-marker"></i>{{city}}</div>
                <div class="fix-header-search"><i class="am-icon-search"></i></div>
            </div>
        </header>
        <div class="am-g am-g-collapse">
            <div class="ads">
                <div id="container">
                    <div id="theTarget" ng-controller="adsCtrl">
                        <div ng-repeat="img in imgs">
                            <!--<div style="background-image: url('{{img}}')"></div>-->
                            <img ng-src="{{img}}" class="ads"/>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="am-g am-g-collapse">
            <div class="am-u-sm-12">
                <div class="shops">
                    <div class="shops-head">
                        &nbsp;&nbsp;附近商家
                    </div>

                    <div class="shops-shop" ng-controller="shopsCtrl">
                        <div class="shop" ng-click="shopping()" ng-repeat="shop in shopsData" repeat-finish>
                            <span class="id" shopID="{{shop.id}}" window-href></span>

                            <div class="am-g ">
                                <div class="am-u-sm-3">
                                    <img ng-src="{{shop.mainImg}}" class="am-radius am-img-responsive shops-shop-img"
                                         alt="超市主图"/>
                                </div>
                                <div class="am-u-sm-9">
                                    <div class="am-g">
                                        <div class="shops-shop-title">
                                            {{ shop.title }}
                                        </div>
                                    </div>
                                    <div class="am-g">
                                        <div class="am-u-sm-4">
                                            <meter max="5" min="0" value="5" style="display:none">hello</meter>
                                        </div>
                                        <div class="am-u-sm-8">
                                            5星好商家
                                        </div>
                                    </div>
                                    <div class="am-g">
                                        起送价 <span class="price">￥{{shop.sellprice}}</span> | 运费 <span class="price">￥{{shop.logisticprice}} </span>
                                        | 30分钟
                                    </div>
                                </div>
                            </div>
                            <div class="am-g">
                                <div class="shops-shop-info">
                                    <!--<img src="/iconfont-hui.png" alt="" class="shops-shop-info-img"/>-->
                                    <div class="am-u-sm-6 am-u-sm-push-1">
                                    <span><i class="am-icon-location-arrow"></i>&nbsp;&nbsp;{{shop.Area.title}}</span>
                                    </div>
                                    <div class="am-u-sm-4 am-u-sm-pull-1">
                                    <span><i class="am-icon-phone"></i>&nbsp;&nbsp;{{shop.phone}}</span>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>

                </div>
            </div>
        </div>
        <% include 'phone/bottom-navbar.html' %>
    </div>
    <div class="am-g">
    <div class="searchPage" ng-controller="searchCtrl">
        <header id="search" data-am-widget="header" class="am-header am-header-default">
            <div class="am-header-left am-header-nav nav-back">
                <a href="" class="" ng-click="back()">
                    <i class="am-header-icon am-icon-angle-left"></i>
                </a>
            </div>
                <div class="searchContain  am-radius">
                    <i class="am-icon-search"></i>
                    <span><input  style="width:50%;background-color:transparent;" type="text" name="shopLocation" placeholder="请输入商家名" ng-model="searchText"/></span>
                </div>
            <div class="searchBtn">
                <button type="button" class="am-btn am-btn-warning am-radius" ng-class="searchText?'':'disableBtn'" ng-click="search()">搜索</button>
            </div>
        </header>
        <div class="am-u-sm-12">
            <div class="shops">
                <div class="shops-shop" ng-controller="shopsCtrl">
                    <div class="shop" ng-click="shopping()" ng-repeat="shop in shopsSearchData" repeat-finish>
                        <span class="id" shopID="{{shop.id}}" window-href></span>

                        <div class="am-g ">
                            <div class="am-u-sm-3">
                                <img ng-src="{{shop.mainImg}}" class="am-radius am-img-responsive shops-shop-img"
                                     alt="超市主图"/>
                            </div>
                            <div class="am-u-sm-9">
                                <div class="am-g">
                                    <div class="shops-shop-title">
                                        {{ shop.title }}
                                    </div>
                                </div>
                                <div class="am-g">
                                    <div class="am-u-sm-4">
                                        <meter max="5" min="0" value="5" style="display:none">hello</meter>
                                    </div>
                                    <div class="am-u-sm-8">
                                        5星好商家
                                    </div>
                                </div>
                                <div class="am-g">
                                    起送价 <span class="price">￥{{shop.sellprice}}</span> | 运费 <span class="price">￥{{shop.logisticprice}} </span>
                                    | 30分钟
                                </div>
                            </div>
                        </div>
                        <div class="am-g">
                            <div class="shops-shop-info">
                                <!--<img src="/iconfont-hui.png" alt="" class="shops-shop-info-img"/>-->
                                <div class="am-u-sm-6 am-u-sm-push-1">
                                    <span><i class="am-icon-location-arrow"></i>&nbsp;&nbsp;{{shop.Area.title}}</span>
                                </div>
                                <div class="am-u-sm-4 am-u-sm-pull-1">
                                    <span><i class="am-icon-phone"></i>&nbsp;&nbsp;{{shop.phone}}</span>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
        </div>
    </div>
    </div>
</div>
</body>
<script type="text/plain" id="imgs">
    <%- @data.imgs %>

</script>
<script src="/dist/phone-commons.js"></script>
<script src="/dist/phone-home.js"></script>
</html>

